package com.wq.bean;

import org.myspringframework.ApplicationContext;
import org.myspringframework.ClassPathXmlApplicationContext;

/**
 * @ description
 * @ author wuyunpeng
 * @ create 2022-10-28 21:26
 */
public class testMySpring {
    public static void main(String[] args){

        ApplicationContext applicationContext = new ClassPathXmlApplicationContext("myspring.xml");
        Vip vipBean = (Vip) applicationContext.getBean("vipBean");
        System.out.println(vipBean);

        OrderDao orderDao = (OrderDao) applicationContext.getBean("orderDaoBean");
        orderDao.placeOrder();

        OrderService orderServiceBean = (OrderService) applicationContext.getBean("orderServiceBean");
        orderServiceBean.serOder();
    }
}
